﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Ninject;

namespace NuGet.Enterprise.Server.Models.Feeds
{
    public class FeedRepository
        : IFeedRepository
    {
        #region Properties

        [Inject]
        public IFeedProvider FeedProvider
        { get; set; }

        #endregion

        #region Methods
        
        public IQueryable<IFeed> GetFeeds()
        {
            return FeedProvider.Feeds.Select(name => FeedProvider.GetFeed(name)).AsQueryable();
        }

        #endregion
    }
}